<?php
/**
 * 其他
 * @author fyl
 * Date: 16-12-13
 */

class OtherService extends BaseService
{
    private static $self = NULL;
    private $mNews      =  NULL;
    private $mTucao      =  NULL;

    public function __construct()
    {
        $this->mNews =   new Involved_NewsModel();
        $this->mTucao =   new Involved_TucaoModel();

    }
    static public function instance()
    {
        if (self::$self == NULL) {
            self::$self = new self;
        }

        return self::$self;
    }

    /**
     * @return mixed
     * 公告列表
     */
    public function NoticeList()
    {

        $list = $this->mNews->OtherNewsList(2);
        return  $list;
    }

    /**
     * @return mixed
     * 公告详情
     */
    public function NoticeDetailed($id)
    {
        $Detailed = $this->mNews->NewsDetailed($id);
        return  $Detailed;
    }


    /**
     * @return mixed
     * 媒体新闻
     */
    public function MediaList()
    {
        $list = $this->mNews->OtherNewsList(1);
        return  $list;
    }

    /**
     * @return mixed
     * 媒体详情
     */
    public function MediaDetailed($auto_id)
    {
        $Detailed = $this->mNews->NewsDetailed($auto_id);
        return  $Detailed;
    }
    public function Tucao($paramObj){
        $aData = [
            'user_id'             =>     $paramObj->user_id,
            'content'           =>     $paramObj->content,
            'phone'           =>     $paramObj->phone,
        ];
         return $this->mTucao->insert($aData);
    }
}
?>